gtkplacessidebar: avoid to use a freed string
authorCarlos Soriano <csoriano@gnome.org>
Thu, 24 Sep 2015 13:54:15 +0000 (15:54 +0200)
committerCarlos Soriano <csoriano@gnome.org>
Fri, 25 Sep 2015 14:10:32 +0000 (16:10 +0200)
commitecc698a282ac69e747026f58ac43eee7958be626
tree0f17b18868189bb96219eb61aa7694d8459e1a0b
parent8eea531f25c2ae9fd5b3f865d860c517f2f0fa0f
gtkplacessidebar: avoid to use a freed string

The string we were using is the representation of the internal text
in the popover entry. However that can be freed before setting the
bookmark label, if i.e. the row is destroyed and therefore the popover
as well.
To avoid that, duplicate the label in a local variable.

One of the consequences is that for those people using development version
we migth screwed its bookmarks file, since the bookmark manager wrote
garbage from the already freed label.

https://bugzilla.gnome.org/show_bug.cgi?id=755215
gtk/gtkplacessidebar.c